package com.ruoyi.system.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 商品管理对象 product
 * 
 * @author gcl
 * @date 2021-05-01
 */
public class Product extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 商品ID */
    private String id;

    /** 商家ID */
    private Long businessId;

    /** 商品名称 */
    @Excel(name = "商品名称")
    private String name;

    /** 商品单价 */
    @Excel(name = "商品单价")
    private BigDecimal price;

    /** 开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd hh:mm")
    @Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd hh:mm")
    private Date startTime;

    /** 结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd hh:mm")
    @Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd hh:mm")
    private Date endTime;

    /** 库存数量 */
    @Excel(name = "库存数量")
    private Long count;

    /** 已售数量 */
    @Excel(name = "已售数量")
    private Long sale;

    /** 商品图片 */
    @Excel(name = "商品图片")
    private String img;

    /** 商品描述 */
    @Excel(name = "商品描述")
    private String describe;

    /** 迭代版本 */
    private Long version;

    public void setId(String id) 
    {
        this.id = id;
    }

    public String getId() 
    {
        return id;
    }
    public void setBusinessId(Long businessId) 
    {
        this.businessId = businessId;
    }

    public Long getBusinessId() 
    {
        return businessId;
    }
    public void setName(String name) 
    {
        this.name = name;
    }

    public String getName() 
    {
        return name;
    }
    public void setPrice(BigDecimal price) 
    {
        this.price = price;
    }

    public BigDecimal getPrice() 
    {
        return price;
    }
    public void setStartTime(Date startTime) 
    {
        this.startTime = startTime;
    }

    public Date getStartTime() 
    {
        return startTime;
    }
    public void setEndTime(Date endTime) 
    {
        this.endTime = endTime;
    }

    public Date getEndTime() 
    {
        return endTime;
    }
    public void setCount(Long count) 
    {
        this.count = count;
    }

    public Long getCount() 
    {
        return count;
    }
    public void setSale(Long sale) 
    {
        this.sale = sale;
    }

    public Long getSale() 
    {
        return sale;
    }
    public void setImg(String img) 
    {
        this.img = img;
    }

    public String getImg() 
    {
        return img;
    }
    public void setDescribe(String describe) 
    {
        this.describe = describe;
    }

    public String getDescribe() 
    {
        return describe;
    }
    public void setVersion(Long version) 
    {
        this.version = version;
    }

    public Long getVersion() 
    {
        return version;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("businessId", getBusinessId())
            .append("name", getName())
            .append("price", getPrice())
            .append("startTime", getStartTime())
            .append("endTime", getEndTime())
            .append("count", getCount())
            .append("sale", getSale())
            .append("img", getImg())
            .append("describe", getDescribe())
            .append("version", getVersion())
            .toString();
    }
}
